Build Contexts
Overview
Contexts define where the content is shown to the users in the Segment. You control where the content should be shown by choosing from a wide range of conditions, like these:
-
Brand information: pages featuring Nike products.
-
Time: show only on Fridays or show between 11 AM and 3 PM.
-
Technology/channel details: mobile site pages, or pages referred directly from Pinterest.
How to Build Contexts
Contexts are built with groups of conditions that define where content should be shown.
-
On the Omnichannel Personalization dashboard, go to Content > Context Library.
-
Click + Add Context.
-
Enter the name of the context.
-
Drag conditions from the left to the box that says "Drag a condition here to start a new group".
Note: When using the Context of "Current URL" no additional work from the client is required to use in a client side/JavaScript integration. However, for a server-side implementation the HTTP_REFERRER in the header of the API call must be modified for this to function properly.
-
Drag different types of conditions to an existing group to include or exclude places where the content should show (logical OR).
-
Add new groups to require both sets of rules at the same time (logical AND).
-
Set up each condition.
Once you've added a condition to a group, you need to set the required values. For example, if you've added a brand condition, the Select a brand link lets you know you haven't chosen the brand yet.
Conditions
Condition |
Description |
---|---|
Brand |
Shows the content on pages that feature a brand. This could include brand pages as well as item pages. Examples: Prada Marc Jacobs |
Product |
Shows the content on pages that feature a specific product. Examples: Hello Kitty Phone Case (497628) item page Item page for any product containing "Hula" |
Product Attribute |
Shows the content on pages for products that have a chosen attribute. Example: Item page for any product with the "Season" attribute set to "Spring" |
Category |
Shows the content on pages associated with a category. Examples: Sports Equipment pages Running Shoes pages |
Search Keyword |
Shows the content on a search results page if the user has searched for a chosen keyword. You can look for exact keyword matches or partial matches. Examples: Searched for "coffee mug" Searched for any terms containing "mug" |
Referer |
Shows the content when a user has just arrived at your site from another site. You can choose from popular search engines or use regular expressions to define which referer sites should be included. You can also look for query parameters. Examples: Referred from Pinterest.com Referred from a Google search |
Time |
Shows the content on specific days of the week or during specific hours of the day. Examples: On Mondays, Wednesdays, and Fridays Between 9 AM and 5 PM |
Page Type |
Shows the content on selected page types. Examples: On item pages On the home page |
Placement |
Shows the content on selected placements. Examples: On Mondays, Wednesdays, and Fridays Between 9 AM and 5 PM |
Channel |
Shows the content on chosen channels. Examples: Mobile Web |
Conditions in Contexts vs. Segments
Many context conditions are similar to segment conditions. Keep in mind that context conditions apply to where the user is at that moment, while segment conditions apply to groups of users who are doing something now or have done something in the past.
For example, if you want to show content on pages for particular products, add a product condition to the context. If you want to show the content to users who have viewed these product pages in the past or bought the products, add a product condition to your segment, not the context. See Build Segments for more examples.